package com.haochang.chunkvod.view.vod.dialog;

import android.os.Parcel;
import android.os.Parcelable;


/**
 *     @author Yangjie
 *     className DialogItemChildInfo
 *     created at  2016/8/29  12:02
 */

public class BaseDialogItemInfo implements Parcelable
{
	private String roomNum;
	private String content;
	private String id;
	private String startTime;
	private String endTime;
	private String title;

	protected BaseDialogItemInfo(Parcel in) {
		roomNum = in.readString();
		content = in.readString();
		id = in.readString();
		startTime = in.readString();
		endTime = in.readString();
		title = in.readString();
		unit = in.readString();
		number = in.readString();
		code = in.readString();
		name = in.readString();
		isSelected = in.readByte() != 0;
	}

	public static final Creator<BaseDialogItemInfo> CREATOR = new Creator<BaseDialogItemInfo>() {
		@Override
		public BaseDialogItemInfo createFromParcel(Parcel in) {
			return new BaseDialogItemInfo(in);
		}

		@Override
		public BaseDialogItemInfo[] newArray(int size) {
			return new BaseDialogItemInfo[size];
		}
	};

	public String getContent()
	{
		return content;
	}

	public void setContent(String content)
	{
		this.content = content;
	}

	public String getTitle() {
		return title;
	}

	public void setTitle(String title) {
		this.title = title;
	}

	public String getEndTime() {
		return endTime;
	}

	public void setEndTime(String endTime) {
		this.endTime = endTime;
	}

	public String getRoomNum() {
		return roomNum;
	}

	public void setRoomNum(String roomNum) {
		this.roomNum = roomNum;
	}

	private String unit;
	private String number;
	private String code;
	private String name;
	private boolean isSelected = false;

	public String getCode()
	{
		return code;
	}

	public void setCode(String code)
	{
		this.code = code;
	}

	public String getName()
	{
		return name;
	}

	public void setName(String name)
	{
		this.name = name;
	}

	public boolean isSelected()
	{
		return isSelected;
	}

	public void setSelected(boolean selected)
	{
		isSelected = selected;
	}

	public String getId()
	{
		return id;
	}

	public void setId(String id)
	{
		this.id = id;
	}

	public String getStartTime()
	{
		return startTime;
	}

	public void setStartTime(String startTime)
	{
		this.startTime = startTime;
	}

	public String getUnit() {
		return unit;
	}

	public void setUnit(String unit) {
		this.unit = unit;
	}

	public String getNumber() {
		return number;
	}

	public void setNumber(String number) {
		this.number = number;
	}

	public BaseDialogItemInfo(String code, String name, boolean isSelected)
	{
		this.code = code;
		this.name = name;
		this.isSelected = isSelected;
	}

	public BaseDialogItemInfo(String code, String name, String content, boolean isSelected)
	{
		this.code = code;
		this.name = name;
		this.content = content;
		this.isSelected = isSelected;
	}

	public BaseDialogItemInfo(String name, boolean isSelected)
	{
		this.name = name;
		this.isSelected = isSelected;
	}

	public BaseDialogItemInfo()
	{
	}

	@Override
	public int describeContents() {
		return 0;
	}

	@Override
	public void writeToParcel(Parcel dest, int flags) {
		dest.writeString(roomNum);
		dest.writeString(content);
		dest.writeString(id);
		dest.writeString(startTime);
		dest.writeString(endTime);
		dest.writeString(title);
		dest.writeString(unit);
		dest.writeString(number);
		dest.writeString(code);
		dest.writeString(name);
		dest.writeByte((byte) (isSelected ? 1 : 0));
	}
}
